<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>RabbitMQ 深度解析</title>
    <link href="https://cdn.staticfile.org/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <link href="https://cdn.staticfile.org/tailwindcss/2.2.19/tailwind.min.css" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;500;600;700&family=Noto+Sans+SC:wght@300;400;500;700&display=swap" rel="stylesheet">
    <script src="https://cdn.jsdelivr.net/npm/mermaid@latest/dist/mermaid.min.js"></script>
    <style>
        body {
            font-family: 'Noto Sans SC', Tahoma, Arial, Roboto, "Droid Sans", "Helvetica Neue", "Droid Sans Fallback", "Heiti SC", "Hiragino Sans GB", Simsun, sans-serif;
            background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
            min-height: 100vh;
        }
        
        .hero-gradient {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        }
        
        .card-hover {
            transition: all 0.3s ease;
            border: 2px solid transparent;
        }
        
        .card-hover:hover {
            transform: translateY(-5px);
            box-shadow: 0 20px 40px rgba(0,0,0,0.1);
            border-color: #667eea;
        }
        
        .section-title {
            position: relative;
            display: inline-block;
        }
        
        .section-title::after {
            content: '';
            position: absolute;
            bottom: -10px;
            left: 0;
            width: 60px;
            height: 4px;
            background: linear-gradient(90deg, #667eea, #764ba2);
            border-radius: 2px;
        }
        
        .advantage-icon {
            background: linear-gradient(135deg, #667eea, #764ba2);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }
        
        .disadvantage-icon {
            background: linear-gradient(135deg, #f093fb, #f5576c);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }
        
        .drop-cap {
            float: left;
            font-size: 4rem;
            line-height: 1;
            font-weight: 700;
            margin-right: 0.5rem;
            margin-top: -0.2rem;
            color: #667eea;
            font-family: 'Noto Serif SC', serif;
        }
        
        .feature-card {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
        }
        
        @keyframes float {
            0% { transform: translateY(0px); }
            50% { transform: translateY(-10px); }
            100% { transform: translateY(0px); }
        }
        
        .float-animation {
            animation: float 3s ease-in-out infinite;
        }
        
        .mermaid {
            background: white;
            padding: 2rem;
            border-radius: 1rem;
            box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        }
    </style>
</head>
<body>
    <!-- Hero Section -->
    <section class="hero-gradient text-white py-20 px-6">
        <div class="max-w-6xl mx-auto text-center">
            <div class="float-animation">
                <i class="fas fa-network-wired text-6xl mb-6 opacity-90"></i>
            </div>
            <h1 class="text-5xl md:text-6xl font-bold mb-6" style="font-family: 'Noto Serif SC', serif;">
                RabbitMQ 深度解析
            </h1>
            <p class="text-xl md:text-2xl opacity-90 max-w-3xl mx-auto leading-relaxed">
                探索企业级消息队列系统的核心优势与挑战
            </p>
            <div class="mt-10 flex justify-center space-x-8">
                <div class="text-center">
                    <i class="fas fa-rocket text-3xl mb-2"></i>
                    <p class="text-sm">高性能</p>
                </div>
                <div class="text-center">
                    <i class="fas fa-shield-alt text-3xl mb-2"></i>
                    <p class="text-sm">高可靠</p>
                </div>
                <div class="text-center">
                    <i class="fas fa-plug text-3xl mb-2"></i>
                    <p class="text-sm">易集成</p>
                </div>
            </div>
        </div>
    </section>

    <!-- Introduction Section -->
    <section class="py-16 px-6">
        <div class="max-w-4xl mx-auto">
            <div class="feature-card rounded-2xl p-10 shadow-xl">
                <p class="text-lg leading-relaxed text-gray-700">
                    <span class="drop-cap">R</span>abbitMQ 是一个流行的开源消息队列系统，它基于 AMQP（高级消息队列协议），在许多场景下被广泛应用于异步处理、消息传递和系统解耦。作为企业级消息中间件的代表，RabbitMQ 以其强大的功能和灵活的架构设计，成为了分布式系统中不可或缺的组件。
                </p>
            </div>
        </div>
    </section>

    <!-- Architecture Visualization -->
    <section class="py-16 px-6 bg-gray-50">
        <div class="max-w-6xl mx-auto">
            <h2 class="section-title text-4xl font-bold text-gray-800 mb-12 text-center">
                <i class="fas fa-sitemap mr-3 text-purple-600"></i>架构概览
            </h2>
            <div class="mermaid">
                graph TB
                    subgraph "生产者"
                        P1[生产者1]
                        P2[生产者2]
                        P3[生产者3]
                    end
                    
                    subgraph "RabbitMQ Broker"
                        subgraph "Exchange 交换机"
                            E1[Direct]
                            E2[Topic]
                            E3[Fanout]
                        end
                        
                        subgraph "Queue 队列"
                            Q1[队列1]
                            Q2[队列2]
                            Q3[队列3]
                        end
                    end
                    
                    subgraph "消费者"
                        C1[消费者1]
                        C2[消费者2]
                        C3[消费者3]
                    end
                    
                    P1 --> E1
                    P2 --> E2
                    P3 --> E3
                    
                    E1 --> Q1
                    E2 --> Q2
                    E3 --> Q3
                    
                    Q1 --> C1
                    Q2 --> C2
                    Q3 --> C3
                    
                    style P1 fill:#667eea,stroke:#fff,color:#fff
                    style P2 fill:#667eea,stroke:#fff,color:#fff
                    style P3 fill:#667eea,stroke:#fff,color:#fff
                    style C1 fill:#764ba2,stroke:#fff,color:#fff
                    style C2 fill:#764ba2,stroke:#fff,color:#fff
                    style C3 fill:#764ba2,stroke:#fff,color:#fff
            </div>
        </div>
    </section>

    <!-- Advantages Section -->
    <section class="py-16 px-6">
        <div class="max-w-6xl mx-auto">
            <h2 class="section-title text-4xl font-bold text-gray-800 mb-12">
                <i class="fas fa-thumbs-up mr-3 advantage-icon"></i>核心优势
            </h2>
            
            <div class="grid md:grid-cols-2 gap-8">
                <!-- 优势卡片1 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-code-branch text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">丰富的协议支持</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>AMQP 支持：</strong>实现了 AMQP 协议，支持复杂的消息传递模式，如发布/订阅、路由、点对点等。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>插件系统：</strong>支持 STOMP、MQTT、HTTP API 等多种插件，满足不同协议和应用场景需求。</p>
                    </div>
                </div>

                <!-- 优势卡片2 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-route text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">强大的消息路由能力</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>灵活的交换机机制：</strong>使用 Direct、Topic、Fanout、Headers 等不同类型交换机实现复杂路由。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>消息队列绑定：</strong>支持将队列绑定到多个交换机，根据路由键灵活处理消息。</p>
                    </div>
                </div>

                <!-- 优势卡片3 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-database text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">可靠性与持久化</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>消息持久化：</strong>支持将消息持久化到磁盘，确保服务器重启或崩溃时消息不丢失。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>确认机制：</strong>提供消息确认机制，失败时可重新投递或发送到死信队列。</p>
                    </div>
                </div>

                <!-- 优势卡片4 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-server text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">高可用性与集群支持</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>高可用性队列：</strong>通过镜像队列机制将数据复制到多个节点，提高可靠性。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>集群模式：</strong>支持多节点部署，提供负载均衡和高可用性。</p>
                    </div>
                </div>

                <!-- 优势卡片5 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-chart-line text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">管理与监控</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>管理界面：</strong>提供用户友好的 Web 管理界面，方便监控和操作。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>监控支持：</strong>可集成 Prometheus、Grafana 等工具进行系统监控。</p>
                    </div>
                </div>

                <!-- 优势卡片6 -->
                <div class="feature-card card-hover rounded-xl p-8">
                    <div class="flex items-start mb-4">
                        <i class="fas fa-code text-3xl advantage-icon mr-4"></i>
                        <h3 class="text-2xl font-bold text-gray-800">开发友好</h3>
                    </div>
                    <div class="space-y-3 text-gray-600">
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>客户端库支持：</strong>提供 Java、Python、Ruby、.NET 等多种语言客户端库。</p>
                        <p><i class="fas fa-check-circle text-green-500 mr-2"></i><strong>社区支持：</strong>拥有广泛的社区支持和丰富的文档资源。</p>
                    </div>
                </div>
            </div>
        </div>
    </section>

    <!-- Disadvantages Section -->
    <section class="py-16 px-6 bg-gray-50">
        <div class="max-w-6xl mx-auto">
            <h2 class="section-title text-4xl font-bold text-gray-800 mb-12">
                <i class="